FROM openjdk:8-jre-slim
MAINTAINER lhz

ENV PARAMS=""

ENV TZ=PRC
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
ADD jmx.yaml /jmx.yaml
ADD springboot-demo.jar /app.jar
ADD jmx_prometheus_javaagent-0.20.0.jar  /jmx.jar
EXPOSE 7070
EXPOSE 8080
ENTRYPOINT ["sh","-c","java -jar  -javaagent:/jmx.jar=7070:/jmx.yaml   $JAVA_OPTS /app.jar $PARAMS"]
